package com.example.monitoringsystem.service.error;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.example.monitoringsystem.bean.Administrator;
import com.example.monitoringsystem.bean.Doctor;
import com.example.monitoringsystem.mapper.AdministratorMapper;
import com.example.monitoringsystem.mapper.DoctorMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional
public class AdminInformationservice {
    @Autowired
    private AdministratorMapper administratorMapper;

/*    //获取Admin的信息
    public Administrator finddoctorbyid() {
        QueryWrapper<Administrator> wrapper = new QueryWrapper<Administrator>();
        int id = Util.getCurrentUser().getId();
        wrapper.eq("administrator_id", id);
        Administrator administrator = administratorMapper.selectOne(wrapper);
        return administrator;
    }
//删除病人信息
    public void updatdescription(String description) {
        UpdateWrapper<Doctor> wrapper = new UpdateWrapper<>();
        int id = Util.getCurrentUser().getId();
        wrapper.set("description", description)
                .eq("doctor_id", id);
    }*/
}
